package com.aikon.wht.properties;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

import javax.validation.constraints.NotNull;

/**
 * Created by haitao.wang on 2016/12/14.
 */
@ConfigurationProperties(prefix = "other")
public class OtherProperties {

    @NotNull
    private String address;

    private String ip;

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getIp() {
        return ip;
    }

    public void setIp(String ip) {
        this.ip = ip;
    }














/*Properties are considered in the following order*/
//    Devtools global settings properties on your home directory (~/.spring-boot-devtools.properties when devtools is active).
//    @TestPropertySource annotations on your tests.
//    @SpringBootTest#properties annotation attribute on your tests.
//    Command line arguments.
//    Properties from SPRING_APPLICATION_JSON (inline JSON embedded in an environment variable or system property)
//    ServletConfig init parameters.
//    ServletContext init parameters.
//    JNDI attributes from java:comp/env.
//    Java System properties (System.getProperties()).
//    OS environment variables.
//    A RandomValuePropertySource that only has properties in random.*.
//    Profile-specific application properties outside of your packaged jar (application-{profile}.properties and YAML variants)
//    Profile-specific application properties packaged inside your jar (application-{profile}.properties and YAML variants)
//    Application properties outside of your packaged jar (application.properties and YAML variants).
//    Application properties packaged inside your jar (application.properties and YAML variants).
//    @PropertySource annotations on your @Configuration classes.
//    Default properties (specified using SpringApplication.setDefaultProperties).
}
